/* eslint-disable */
import request from "@/request";

/** listCities POST /api/api/shopPart/region/cities */
export async function listCitiesUsingPost(
  body: API.RegionDict,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseListRegionDict_>(
    "/api/api/shopPart/region/cities",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** listDistricts POST /api/api/shopPart/region/districts */
export async function listDistrictsUsingPost(
  body: API.RegionDict,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseListRegionDict_>(
    "/api/api/shopPart/region/districts",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** getByCode POST /api/api/shopPart/region/get */
export async function getByCodeUsingPost(
  body: API.RegionDict,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseRegionDict_>("/api/api/shopPart/region/get", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    data: body,
    ...(options || {}),
  });
}

/** listProvinces GET /api/api/shopPart/region/provinces */
export async function listProvincesUsingGet(options?: { [key: string]: any }) {
  return request<API.BaseResponseListRegionDict_>(
    "/api/api/shopPart/region/provinces",
    {
      method: "GET",
      ...(options || {}),
    }
  );
}
